/*
 * File:   KeyCommand.h
 * Author: Elevator
 *
 * Created on 18 Май 2013 г., 0:23
 */

#ifndef DATA_COMMAND_H
#define DATA_COMMAND_H

#include "CommandType.h"

namespace data {

	struct Command {
	public:
		Command( int key, CommandType type ) :
		_key( key ),
		_type( type )
		{ }

		inline int GetKey( ) const { return _key; }
		inline void SetKey( int key ) { _key = key; }

		inline CommandType GetType( ) const { return _type; }
		inline void SetType( CommandType type ) { _type = type; }

	private:
		int _key;
		CommandType _type;
	};

	inline bool operator == (const Command& a, const Command& b) {
		return
			a.GetKey() == b.GetKey() &&
			a.GetType() == b.GetType();
	}
}
#endif	/* COMMAND_H */
